package siyuan.run.nacos.config.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @program: sy
 * @description:
 * @author: SY
 * @create: 2020-12-20 00:54
 **/
@RestController
@RefreshScope
public class SampleController {

    @Value("${mysql.ip}")
    private String ip;
    @Value("${mysql.port}")
    private String port;

    @GetMapping("get")
    public String get(){
        return ip+":"+port;
    }

}
